import request from '@/utils/request'

// 查询渠道对应业务员列表
export function listDealeruser(query) {
  return request({
    url: '/DealerUserMain/dealeruser/list',
    method: 'get',
    params: query
  })
}

// 查询渠道对应业务员详细
export function getDealeruser(userId) {
  return request({
    url: '/DealerUserMain/dealeruser/' + userId,
    method: 'get'
  })
}

// 新增渠道对应业务员
export function addDealeruser(data) {
  return request({
    url: '/DealerUserMain/dealeruser',
    method: 'post',
    data: data
  })
}

// 修改渠道对应业务员
export function updateDealeruser(data) {
  return request({
    url: '/DealerUserMain/dealeruser',
    method: 'put',
    data: data
  })
}

// 删除渠道对应业务员
export function delDealeruser(userId) {
  return request({
    url: '/DealerUserMain/dealeruser/' + userId,
    method: 'delete'
  })
}
